function rotate(line,angle)
    rad = angle*pi/180;
    R = [cos(rad) -sin(rad);
        sin(rad) cos(rad)];
    
    line = (R * line')';
    plot(line(:,1),line(:,2))
end